public class LinearSearchTest {
    public static void main(String[] args) {
        // Linear Search
        String[] arr = new String[]{"JJ", "DD", "MM", "BB", "GG", "AA", "PP"};
        String dest = "AA";
        int ind = 0;
        for (int i = 0; i < arr.length; i++) {
            ind = i;
            if (arr[i] == dest) {
                System.out.println("Dest: " + dest + "\tindex: " + i);
            }
        }
        if (ind == arr.length) {
            System.out.println("Not Found");
        }
    }
}

